<template>
  <div>
    <el-row>
      <el-col :span="16">
        <h-editor @change="onInputChange" :initContent="editContent"></h-editor>

      </el-col>
      <el-col style="display: flex;justify-content: center" :span="8">
        <div v-html="editContent" style="height: 667px;width: 375px;border: 1px solid gray;overflow-y: auto;"></div>

      </el-col>
    </el-row>
  </div>

</template>

<script>
  import HEditor from '../../components/HEditor'

  export default {
    name: "EditorTest",
    components: {
      HEditor
    },
    data() {
      return {
        editContent: ''
      }
    },
    methods: {
      onInputChange(content) {
        this.editContent = content
        console.log(this.editContent)
      },
      getContent() {
      }
    },
    created() {
      console.log("初始化编辑器")
      this.editContent = '哈哈哈'
    }
  }
</script>

<style scoped>

</style>
